package yesjava;

import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;

public class Test2 {
     public static List<Integer> changeArray2List(int[] arr){
         Integer[] arr1 = new Integer[arr.length];
         for (int i = 0; i < arr.length; i++) {
             arr1[i]=arr[i];
         }
         return Arrays.asList(arr1) ;
     }

    public static void main(String[] args) {
        List<Integer> list = changeArray2List(new int[]{123, 125, 85, 457, 44});
        for (Integer integer : list) {
            System.out.println(integer);
        }
    }
}
